import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;

/**
 * @author ShenTuZhiGang
 * @version 1.0.0
 * @email 1600337300@qq.com
 * @date 2021-08-21 15:03
 */
public class ExamNetEase2021082101 {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        List<Long> list = new ArrayList<>();
        while (scanner.hasNext()){
            list.add(scanner.nextLong());
        }
        int ans =0 ;
        for (int i = 0; i < list.size() -1; i++) {
            for (int j = i+1; j <= list.size() -1; j++) {
                if (list.get(i) + list.get(j)<list.get(list.size()-1)){
                    ans ++;
                }
            }
        }
        System.out.println(ans);
    }
}
